<html>
	<head>
		<meta charset="utf-8"></meta>
		<title>BPicker</title>
		<link href="./style.css" rel="stylesheet" type="text/css"/>
	</head>
	<body>
		<div class="class" name="BPicker">
			<h1>BPicker</h1>
			<p>继承自<a href="BObject.html">BObject</a></p>
			<p id="resume">BPicker是场景拾取类，是基于一条线对指定的场景范围中的对象进行几何求交以实现拾取功能。<a href="#desc">详细</a></p>
			<h2>public</h2>
			<table id="public">
				<tr><td align="right"/><td><a href="#BPicker()">BPicker</a>();</td></tr>
				<tr><td align="right"/><td><a href="#BPicker(const BLine&)">BPicker</a>(const BLine& line);</td></tr>
				<tr><td align="right"/><td><a href="#BPicker(const BVector&, const BVector&)">BPicker</a>(const BVector& begin, const BVector& end);</td></tr>
				<tr><td align="right"/><td><a href="#~BPicker()">~BPicker</a>();</td></tr>
				<tr><td align="right">void </td><td><a href="#setHitNum(int)">setHitNum</a>(int hitNum);</td></tr>
				<tr><td align="right">int </td><td><a href="#hitNum() const">hitNum</a>() const;</td></tr>
				<tr><td align="right">void </td><td><a href="#setLine(const BVector&, const BVector&)">setLine</a>(const BVector& begin, const BVector& end);</td></tr>
				<tr><td align="right">void </td><td><a href="#setLine(const BLine&)">setLine</a>(const BLine& line);</td></tr>
				<tr><td align="right">const BLine&amp; </td><td><a href="#line() const">line</a>() const;</td></tr>
				<tr><td align="right">bool </td><td><a href="#exclude(const BObject*)">exclude</a>(const BObject* object);</td></tr>
				<tr><td align="right">bool </td><td><a href="#include(const BObject*)">include</a>(const BObject* object);</td></tr>
				<tr><td align="right">int </td><td><a href="#exclusionCount() const">exclusionCount</a>() const;</td></tr>
				<tr><td align="right">const BObject* </td><td><a href="#exclusion(int) const">exclusion</a>(int index) const;</td></tr>
				<tr><td align="right">void </td><td><a href="#clearExclusions()">clearExclusions</a>();</td></tr>
				<tr><td align="right">int </td><td><a href="#inclusionCount() const">inclusionCount</a>() const;</td></tr>
				<tr><td align="right">const BObject* </td><td><a href="#inclusion(int) const">inclusion</a>(int index) const;</td></tr>
				<tr><td align="right">void </td><td><a href="#clearInclusions()">clearInclusions</a>();</td></tr>
				<tr><td align="right">BPickHit* </td><td><a href="#apply(BScene*)">apply</a>(BScene* scene);</td></tr>
				<tr><td align="right">BPickHit* </td><td><a href="#apply(BGroup*)">apply</a>(BGroup* group);</td></tr>
				<tr><td align="right">BPickHit* </td><td><a href="#apply(BNode*)">apply</a>(BNode* node);</td></tr>
				<tr><td align="right">BPickHit* </td><td><a href="#apply(BShape*)">apply</a>(BShape* shape);</td></tr>
				<tr><td align="right">int </td><td><a href="#itemCount() const">itemCount</a>() const;</td></tr>
				<tr><td align="right">BPickHit* </td><td><a href="#hit(int)">hit</a>(int index);</td></tr>
				<tr><td align="right">const BPickHit* </td><td><a href="#hit(int) const">hit</a>(int index) const;</td></tr>
				<tr><td align="right">void </td><td><a href="#clear()">clear</a>();</td></tr>
			</table>
			<h2>protected</h2>
			<table id="protected">
				<tr><td align="right">bool </td><td><a href="#ignore(const BShape*) const">ignore</a>(const BShape* shape) const;</td></tr>
				<tr><td align="right">bool </td><td><a href="#ignore(const BNode*) const">ignore</a>(const BNode* node) const;</td></tr>
				<tr><td align="right">bool </td><td><a href="#ignore(const BGroup*) const">ignore</a>(const BGroup* group) const;</td></tr>
				<tr><td align="right">bool </td><td><a href="#ignore(const BElement*) const">ignore</a>(const BElement* element) const;</td></tr>
				<tr><td align="right">bool </td><td><a href="#record(BPickHit*)">record</a>(BPickHit* hit);</td></tr>
				<tr><td align="right">BPickHit* </td><td><a href="#create() const">create</a>() const;</td></tr>
				<tr><td align="right">BMatrix </td><td><a href="#matrix() const">matrix</a>() const;</td></tr>
				<tr><td align="right">virtual void </td><td><a href="#reset()">reset</a>();</td></tr>
				<tr><td align="right">virtual void </td><td><a href="#finish()">finish</a>();</td></tr>
				<tr><td align="right">virtual void </td><td><a href="#pick(const BLine&, BGroup*)">pick</a>(const BLine& line, BGroup* group);</td></tr>
				<tr><td align="right">virtual void </td><td><a href="#pick(const BLine&, BNode*)">pick</a>(const BLine& line, BNode* node);</td></tr>
				<tr><td align="right">virtual void </td><td><a href="#pick(const BLine&, BShape*)">pick</a>(const BLine& line, BShape* shape);</td></tr>
				<tr><td align="right">virtual void </td><td><a href="#pick(const BLine&, BMesh*)">pick</a>(const BLine& line, BMesh* mesh);</td></tr>
				<tr><td align="right">virtual void </td><td><a href="#pick(const BLine&, BGeometry*)">pick</a>(const BLine& line, BGeometry* geometry);</td></tr>
				<tr><td align="right">virtual void </td><td><a href="#pick(const BLine&, BSphere*)">pick</a>(const BLine& line, BSphere* sphere);</td></tr>
				<tr><td align="right">virtual void </td><td><a href="#pick(const BLine&, BGeoSphere*)">pick</a>(const BLine& line, BGeoSphere* geosphere);</td></tr>
				<tr><td align="right">virtual void </td><td><a href="#pick(const BLine&, BCylinder*)">pick</a>(const BLine& line, BCylinder* cylinder);</td></tr>
				<tr><td align="right">virtual void </td><td><a href="#pick(const BLine&, BCone*)">pick</a>(const BLine& line, BCone* cone);</td></tr>
				<tr><td align="right">virtual void </td><td><a href="#pick(const BLine&, BTube*)">pick</a>(const BLine& line, BTube* tube);</td></tr>
				<tr><td align="right">virtual void </td><td><a href="#pick(const BLine&, BTorus*)">pick</a>(const BLine& line, BTorus* torus);</td></tr>
				<tr><td align="right">virtual void </td><td><a href="#pick(const BLine&, BBillboard*)">pick</a>(const BLine& line, BBillboard* billboard);</td></tr>
				<tr><td align="right">virtual void </td><td><a href="#pick(const BLine&, BTerrain*)">pick</a>(const BLine& line, BTerrain* terrain);</td></tr>
				<tr><td align="right">virtual void </td><td><a href="#pick(const BLine&, BSurface*)">pick</a>(const BLine& line, BSurface* surface);</td></tr>
				<tr><td align="right">virtual void </td><td><a href="#pick(const BLine&, BGridPlane*)">pick</a>(const BLine& line, BGridPlane* gridplane);</td></tr>
			</table>
			<div id="desc">
				<h2>详细介绍：</h2>
				<p>BPicker是场景拾取类，是基于一条线对指定的场景范围中的对象进行几何求交以实现拾取功能。此拾取功能是场景交互的核心之一，三维视图控件（BViewer）中的pick()方法也是使用此类的功能。</p>
				<p>参考：<text>拾取结果（</text><a href="BPickHit.html">BPickHit</a>）。</p>
			</div>
			<h2 id="docs">成员文档：</h2>
			<div id="BPicker()">
				<h3>BPicker();</h3>
				<p>Constructs Picker.</p>
			</div>
			<div id="BPicker(const BLine&)">
				<h3>BPicker(const BLine&amp; line);</h3>
				<p>Constructs picker with line. The line could be set by setLine().</p>
			</div>
			<div id="BPicker(const BVector&, const BVector&)">
				<h3>BPicker(const BVector&amp; begin, const BVector&amp; end);</h3>
			</div>
			<div id="~BPicker()">
				<h3>~BPicker();</h3>
				<p>Destroys picker.</p>
			</div>
			<div id="setHitNum(int)">
				<h3>void setHitNum(int hitNum);</h3><p>设置拾取结果的最大缓存数量，如果太多往往是浪费资源。通常只要一个最优结果即距离摄像机最近的结果，所以默认的缓存数量为1。</p>
			</div>
			<div id="hitNum() const">
				<h3>int hitNum() const;</h3><p>取得拾取结果的最大缓存数量。</p>
			</div>
			<div id="setLine(const BVector&, const BVector&)">
				<h3>void setLine(const BVector&amp; begin, const BVector&amp; end);</h3><p>设置用于拾取的线，begin和end指定其起始点和结束点。</p>
			</div>
			<div id="setLine(const BLine&)">
				<h3>void setLine(const BLine&amp; line);</h3>
				<p>设置用于拾取的线。</p>
			</div>
			<div id="line() const">
				<h3>const BLine&amp; line() const;</h3>
				<p>获得用于拾取的线。</p>
			</div>
			<div id="exclude(const BObject*)">
				<h3>bool exclude(const BObject* object);</h3><p>添加一个被排除的对象，当一个对象被排除后，即便它是显示的也不会被忽略。但包含机制的优先级大于排除机制，即当一个对象被包含了，那么不再关心是否被排除了。</p>
			</div>
			<div id="include(const BObject*)">
				<h3>bool include(const BObject* object);</h3><p>添加一个被包含的对象，当一个对象被包含后，通过ignore(object)方法总是会失败的，即便对象被隐藏也不会被忽略了。通常用于对特定的隐藏对象开启拾取功能。</p>
			</div>
			<div id="exclusionCount() const">
				<h3>int exclusionCount() const;</h3>
				<p>获得被排除的对象的数量。</p>
			</div>
			<div id="exclusion(int) const">
				<h3>const BObject* exclusion(int index) const;</h3>
				<p>获得指定索引位置的被排除的对象。</p>
			</div>
			<div id="clearExclusions()">
				<h3>void clearExclusions();</h3>
				<p>清空所有被排除的对象数据。</p>
			</div>
			<div id="inclusionCount() const">
				<h3>int inclusionCount() const;</h3><p>获得被包含的对象的数量。</p>
			</div>
			<div id="inclusion(int) const">
				<h3>const BObject* inclusion(int index) const;</h3><p>获得指定索引位置的被包含的对象。</p>
			</div>
			<div id="clearInclusions()">
				<h3>void clearInclusions();</h3>
			</div>
			<div id="apply(BScene*)">
				<h3>BPickHit* apply(BScene* scene);</h3>
				<p>Start picking item under the scene. if hitting happened return the nearest item.</p>
			</div>
			<div id="apply(BGroup*)">
				<h3>BPickHit* apply(BGroup* group);</h3>
			</div>
			<div id="apply(BNode*)">
				<h3>BPickHit* apply(BNode* node);</h3>
				<p>Start picking item under the node, if hitting happened return the nearest item.</p>
			</div>
			<div id="apply(BShape*)">
				<h3>BPickHit* apply(BShape* shape);</h3>
				<p>Start picking item for shape, if successed return shape.</p>
			</div>
			<div id="itemCount() const">
				<h3>int itemCount() const;</h3>
				<p>Get number of hitting items.</p>
			</div>
			<div id="hit(int)">
				<h3>BPickHit* hit(int index);</h3>
			</div>
			<div id="hit(int) const">
				<h3>const BPickHit* hit(int index) const;</h3>
			</div>
			<div id="clear()">
				<h3>void clear();</h3>
			</div>
			<div id="ignore(const BShape*) const">
				<h3>bool ignore(const BShape* shape) const;</h3>
			</div>
			<div id="ignore(const BNode*) const">
				<h3>bool ignore(const BNode* node) const;</h3>
			</div>
			<div id="ignore(const BGroup*) const">
				<h3>bool ignore(const BGroup* group) const;</h3>
			</div>
			<div id="ignore(const BElement*) const">
				<h3>bool ignore(const BElement* element) const;</h3>
			</div>
			<div id="record(BPickHit*)">
				<h3>bool record(BPickHit* hit);</h3>
			</div>
			<div id="create() const">
				<h3>BPickHit* create() const;</h3>
			</div>
			<div id="matrix() const">
				<h3>BMatrix matrix() const;</h3>
			</div>
			<div id="reset()">
				<h3>virtual void reset();</h3>
			</div>
			<div id="finish()">
				<h3>virtual void finish();</h3>
			</div>
			<div id="pick(const BLine&, BGroup*)">
				<h3>virtual void pick(const BLine&amp; line, BGroup* group);</h3>
			</div>
			<div id="pick(const BLine&, BNode*)">
				<h3>virtual void pick(const BLine&amp; line, BNode* node);</h3>
			</div>
			<div id="pick(const BLine&, BShape*)">
				<h3>virtual void pick(const BLine&amp; line, BShape* shape);</h3>
			</div>
			<div id="pick(const BLine&, BMesh*)">
				<h3>virtual void pick(const BLine&amp; line, BMesh* mesh);</h3>
			</div>
			<div id="pick(const BLine&, BGeometry*)">
				<h3>virtual void pick(const BLine&amp; line, BGeometry* geometry);</h3>
			</div>
			<div id="pick(const BLine&, BSphere*)">
				<h3>virtual void pick(const BLine&amp; line, BSphere* sphere);</h3>
			</div>
			<div id="pick(const BLine&, BGeoSphere*)">
				<h3>virtual void pick(const BLine&amp; line, BGeoSphere* geosphere);</h3>
			</div>
			<div id="pick(const BLine&, BCylinder*)">
				<h3>virtual void pick(const BLine&amp; line, BCylinder* cylinder);</h3>
			</div>
			<div id="pick(const BLine&, BCone*)">
				<h3>virtual void pick(const BLine&amp; line, BCone* cone);</h3>
			</div>
			<div id="pick(const BLine&, BTube*)">
				<h3>virtual void pick(const BLine&amp; line, BTube* tube);</h3>
			</div>
			<div id="pick(const BLine&, BTorus*)">
				<h3>virtual void pick(const BLine&amp; line, BTorus* torus);</h3>
			</div>
			<div id="pick(const BLine&, BBillboard*)">
				<h3>virtual void pick(const BLine&amp; line, BBillboard* billboard);</h3>
			</div>
			<div id="pick(const BLine&, BTerrain*)">
				<h3>virtual void pick(const BLine&amp; line, BTerrain* terrain);</h3>
			</div>
			<div id="pick(const BLine&, BSurface*)">
				<h3>virtual void pick(const BLine&amp; line, BSurface* surface);</h3>
			</div>
			<div id="pick(const BLine&, BGridPlane*)">
				<h3>virtual void pick(const BLine&amp; line, BGridPlane* gridplane);</h3>
			</div>
		</div>
	</body>
</html>